x86: stop handling MSR_IA32_XSS save/restore in implementation code
authorPaul Durrant <paul.durrant@citrix.com>
Thu, 14 Mar 2019 13:55:00 +0000 (14:55 +0100)
committerJan Beulich <jbeulich@suse.com>
Tue, 9 Apr 2019 13:08:49 +0000 (15:08 +0200)
commit4ec08bb826765e788acd0aaccf8c444df8de8019
treeff10bba8c663a2bf3c6445b570a717e90b816a17
parent943c474283a34e48e5088af2ad67d7a56320fbd7
x86: stop handling MSR_IA32_XSS save/restore in implementation code

Saving and restoring the value of this MSR is currently handled by
implementation-specific code despite it being architectural. This patch
moves handling of accesses to this MSR from hvm.c into the msr.c, thus
allowing the common MSR save/restore code to handle it.

This patch also adds proper checks of CPUID policy in the new get/set code.

NOTE: MSR_IA32_XSS is the last MSR to be saved and restored by
      implementation-specific code. This patch therefore removes the
      (VMX) definitions and of the init_msr(), save_msr() and
      load_msr() hvm_funcs, as they are no longer necessary. The
      declarations of and calls to those hvm_funcs will be cleaned up
      by a subsequent patch.

Signed-off-by: Paul Durrant <paul.durrant@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Kevin Tian <kevin.tian@intel.com>
xen/arch/x86/hvm/hvm.c
xen/arch/x86/hvm/vmx/vmx.c
xen/arch/x86/msr.c